shareFile

fun shareFile(_: Nothing = nothing, authority: String = ".ly.img.editor.fileprovider", file: File, mimeType: MimeType)

A helper function that opens a system dialog to share the file. Note that the uri of the file is resolved on a background thread, therefore the system dialog is opened asynchronously. If the uri resolution fails, the error state is set instead of throwing.

Parameters

authority

the authority of FileProvider defined in a element in your app's manifest.

file

the file that should be shared.

mimeType

the mime type of the file that is used to open the system dialog.